package com.dili.dd.gpi.service.impl;

import com.dili.dd.gpi.service.DmaDataService;
import com.dili.dd.gpi.util.DataServiceClient;
import com.dili.dd.gpi.util.spring.DataSourceLookupKey;
import com.dili.dd.gpi.util.spring.RequireDataSource;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;

/**
 * Created by 思思君 on 2015/10/14.
 */
@Service
public class DmaDataServiceImpl implements DmaDataService
{
    @Resource
    private DataServiceClient dataServiceClient;

    @Override
    @RequireDataSource(key = DataSourceLookupKey.DMA_DATASOURCE)
    public String insertUserAppkey(String userId, String appkey)
    {
        return dataServiceClient.insertUserAppkey(userId, appkey);
    }

    @Override
    @RequireDataSource(key = DataSourceLookupKey.DMA_DATASOURCE)
    public String deleteUserAppkey(String userId, String appkey)
    {
        return dataServiceClient.deleteUserAppkey(userId, appkey);
    }
}
